#ifndef _LED_MATRIX_H_
#define _LED_MATRIX_H_

#include "bsp.h"

#define LED_MATRIX_GPIO_PeriphClockFunc   RCC_APB2PeriphClockCmd
#define LED_MATRIX_GPIO_PeriphClock       RCC_APB2Periph_GPIOA
#define LED_MATRIX_ROW_PORT               GPIOA
#define LED_MATRIX_ROW_PIN1               GPIO_Pin_0
#define LED_MATRIX_ROW_PIN2               GPIO_Pin_1
#define LED_MATRIX_ROW_PIN3               GPIO_Pin_9
#define LED_MATRIX_ROW_PIN4               GPIO_Pin_10

#define LED_MATRIX_COLNUMN_PeriphClockFunc   RCC_APB2PeriphClockCmd
#define LED_MATRIX_COLNUMN_PeriphClock       RCC_APB2Periph_GPIOB
#define LED_MATRIX_COLNUMN_PORT               GPIOB
#define LED_MATRIX_COLNUMN_DS             GPIO_Pin_12
#define LED_MATRIX_COLNUMN_ST_CP          GPIO_Pin_13//GPIO_Pin_13   //RCK   DAT MOVE TO REG
#define LED_MATRIX_COLNUMN_SH_CP          GPIO_Pin_14//GPIO_Pin_14   //SCK   DAT MOVE TO NEXT
#define LED_MATRIX_COLNUMN_MR             GPIO_Pin_15   //LOW RESET


int8_t hdl_led_matrix_init(void);

void hdl_row_scan(uint8_t row);
void hdl_colnumn_data(uint8_t dat0,uint8_t dat1,uint8_t dat2,uint8_t dat3);

void hdl_screen_full_check(void);

#endif

